//
//  ADModel.h
//  RainbowFM
//
//  Created by chenli on 14/12/28.
//  Copyright (c) 2014年 RB. All rights reserved.
//

#import <Foundation/Foundation.h>
/*
广告位code
code=1 ----首页顶部广告
code=2----彩虹商城顶部广告
code=3---直播页面下部商家推荐广告
code=4---直播页面顶部文字条广告
code=5---客户端进入时大图全屏广告（需要停留3秒，加载图片的同时可同时拉起进首页的接口）
*/

@interface ADListItem : NSObject

@property (nonatomic,strong) NSString *backParam;
@property (nonatomic,strong) NSString *imgBig;
@property (nonatomic,strong) NSString *imgSmall;
@property (nonatomic,strong) NSString *interval;
@property (nonatomic,strong) NSString *name;
@property (nonatomic,strong) NSString *offlineTime;
@property (nonatomic,strong) NSString *onlineTime;
@property (nonatomic,strong) NSString *relationId;
@property (nonatomic,strong) NSString *relationTitle;
@property (nonatomic,strong) NSString *text;
@property (nonatomic,strong) NSString *time;
@property (nonatomic,strong) NSString *type;
@property (nonatomic,strong) NSString *url;
@property (nonatomic,strong) NSString *video;


-(instancetype)initWithAttributes:(NSDictionary *)attributes;

@end


@interface ADModel : NSObject

+(instancetype)sharedModel;


-(void)fetchADListWithChannel:(NSString *)channel code:(NSString *)code_ result:(void(^)(BOOL success,NSArray *array))res;


-(void)adStatisticsWithBackParam:(NSString *)backParam result:(void(^)(BOOL success,NSString *msg))res;

@end
